home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Tech Arsenal 1
/
Tech Arsenal (Arsenal Computer).ISO
/
tek-01
/
wics.zip
/
WICS.H
< prev
next >
Wrap
C/C++ Source or Header
|
1993-03-04
|
36KB
|
927 lines
/*==================================================================================*/
/* */
/* W I C S V e r s i o n 1 . 0 0 */
/* */
/* Main Header File for the Windows Interface Construction Set (WICS). */
/* This header file contains definitions for the WICS custom control library */
/* (WICSCC.DLL), the custom dialog box library (WCD.DLL) and the custom classes */
/* found in WICS.LIB. */
/* */
/* WICS is written to work in conjunction with the Object Windows Libraries (OWL) */
/* provided with Borland C++ Version 3.1. As such, this header file is written to */
/* be compiled with the Borland C++ complier. If another complier is to be used, */
/* some changes in this header file may be neccessary to comply with that */
/* complier's syntax requirements. */
/* */
/*==================================================================================*/
/*----------------------------------------------------------------------------------*/
/* Windows Interface Construction Set - WICS */
/* Copyright ⌐ 1993, Microdyne Development Technologies */
/* All rights reserved. */
/*----------------------------------------------------------------------------------*/
/* Version 1.00 March 1993 */
/*----------------------------------------------------------------------------------*/
#ifndef _WICS_H /* prevent multiple includes */
#define _WICS_H
#define CM_PRINTERSETUP 24350
#define CM_PRINT 24351
#ifndef RC_INVOKED
#include <windows.h> /* Make sure WINDOWS.H is included */
#pragma option -a- /* Assume byte packing throughout */
#endif /* !RC_INVOKED */
#define ERR_INVALID_PATH 100
#define ERR_FILEEXISTS 101
#define ERR_NOFILE 102
#define ERR_OTHER 999
/*----------------------------------------------------------------------------------*/
/* Button Control Area */
/* */
/* The following lines pertain to the WICS Button Control. The control can be */
/* found in WICSCC.DLL. */
/*----------------------------------------------------------------------------------*/
/*----------------------------------------------------------------------------------*/
/* Define additional standard Button ID's. These button IDs coorespond to bitmaps */
/* in WICSCC.DLL. */
/*----------------------------------------------------------------------------------*/
#define IDUNDO 8
#define IDADD 9
#define IDDELETE 10
#define IDEDIT 11
#define IDDONE 12
#define IDRESIZE 13
#define IDEDITPALETTE 14
#define IDAPPLY 15
#define IDFINDNEXT 16
#define IDREPLACE 17
#define IDREPLACEALL 18
#define IDSETUP 19
#define IDOPTIONS 20
#define IDFIND 21
#ifndef IDHELP
#define IDHELP 998
#endif
/*----------------------------------------------------------------------------------*/
/* Define standard ID's for the Icon Bar buttons. These button IDs coorespond to */
/* bitmaps in WICSCC.DLL. */
/*----------------------------------------------------------------------------------*/
#define IBID_FILEOPEN 801
#define IBID_FILESAVE 802
#define IBID_SEARCH 803
#define IBID_CUT 804
#define IBID_COPY 805
#define IBID_PASTE 806
#define IBID_PRINTER 807
#define IBID_BOLD 808
#define IBID_ITALIC 809
#define IBID_LEFT 810
#define IBID_CENTER 811
#define IBID_RIGHT 812
#define IBID_PAGE 813
#define IBID_LEFTTAB 814
#define IBID_CENTERTAB 815
#define IBID_RIGHTTAB 816
#define IBID_DECIMALTAB 817
#define IBID_EDIT 818
#define IBID_SUM 819
#define IBID_JUSTIFIED 820
#define IBID_SPELLCHECK 821
#define IBID_ERASE 822
#define IBID_INDENT 823
#define IBID_OUTDENT 824
#define IBID_UNDERLINE 825
#define IBID_BULLET 826
#define IBID_DRAW 827
#define IBID_FRAME 828
#define IBID_CHART 829
#define IBID_MAIL 830
#define IBID_DECIMAL 831
#define IBID_UNDO 832
/*----------------------------------------------------------------------------------*/
/* Define the WICS Button styles... */
/*----------------------------------------------------------------------------------*/
#define WBS_PUSHBUTTON 0x00000000L
#define WBS_DEFPUSHBUTTON 0x00000001L
#define WBS_ICONBUTTON 0x00000800L
#define WBS_STATEBUTTON 0x00000400L
#define WBS_REPEATBUTTON 0x00000200L
#define WBM_SETBITMAP WM_USER+100
#define WBM_STOPREPEAT WM_USER+101
#define WBM_SETCOMMANDCODE WM_USER+102
#define STATE_NORMAL 1
#define STATE_PRESSED 2
#define STATE_HASFOCUS 3
/*----------------------------------------------------------------------------------*/
/* Define notification messages for the X-Y Button Control */
/*----------------------------------------------------------------------------------*/
#define WXYN_UPPRESSED 100
#define WXYN_RIGHTPRESSED 101
#define WXYN_DOWNPRESSED 102
#define WXYN_LEFTPRESSED 103
/*
/*
/************ End of Button Control Section *************/
/*----------------------------------------------------------------------------------*/
/* Hierarchial List Box Control Area */
/* */
/* The following lines pertain to the Hierarchial List Box Control. The Hierarchial*/
/* List Box Control is found in WICSCC.DLL. */
/*----------------------------------------------------------------------------------*/
#define HLBS_NOTIFY 0x00000001L
#define HLBS_SORT 0x00000002L
#define HLBS_NOREDRAW 0x00000004L
#define HLBS_MULTIPLESEL 0x00000008L
#define HLBS_OWNERDRAWFIXED 0x00000010L
#define HLBS_OWNERDRAWVARIABLE 0x00000020L
#define HLBS_HASSTRINGS 0x00000040L
#define HLBS_USETABSTOPS 0x00000080L
#define HLBS_NOINTEGRALHEIGHT 0x00000100L
#define HLBS_MULTICOLUMN 0x00000200L
#define HLBS_WANTKEYBOARDINPUT 0x00000400L
#define HLBS_EXTENDEDSEL 0x00000800L
#define HLBS_DISABLENOSCROLL 0x00001000L
#define HLBS_FOLDERBITMAPS 0x00002000L
#define HLBS_STANDARD (HLBS_NOTIFY | HLBS_SORT | WS_VSCROLL | WS_BORDER)
#define HLB_ADDSTRING (WM_USER+1)
#define HLB_INSERTSTRING (WM_USER+2)
#define HLB_DELETESTRING (WM_USER+3)
#define HLB_RESETCONTENT (WM_USER+5)
#define HLB_SETSEL (WM_USER+6)
#define HLB_SETCURSEL (WM_USER+7)
#define HLB_GETSEL (WM_USER+8)
#define HLB_GETCURSEL (WM_USER+9)
#define HLB_GETTEXT (WM_USER+10)
#define HLB_GETTEXTLEN (WM_USER+11)
#define HLB_GETCOUNT (WM_USER+12)
#define HLB_SELECTSTRING (WM_USER+13)
#define HLB_GETTOPINDEX (WM_USER+15)
#define HLB_FINDSTRING (WM_USER+16)
#define HLB_GETSELCOUNT (WM_USER+17)
#define HLB_GETSELITEMS (WM_USER+18)
#define HLB_GETHORIZONTALEXTENT (WM_USER+20)
#define HLB_SETHORIZONTALEXTENT (WM_USER+21)
#define HLB_SETTOPINDEX (WM_USER+24)
#define HLB_GETITEMRECT (WM_USER+25)
#define HLB_GETITEMDATA (WM_USER+26)
#define HLB_SETITEMDATA (WM_USER+27)
#define HLB_SELITEMRANGE (WM_USER+28)
#define HLB_SETITEMHEIGHT (WM_USER+33)
#define HLB_GETITEMHEIGHT (WM_USER+34)
#define HLB_FINDSTRINGEXACT (WM_USER+35)
#define HLB_SETBITMAPS (WM_USER+36)
#define HLB_DELETESUBTREE (WM_USER+37)
#define HLB_OPENSUBTREE (WM_USER+38)
#define HLB_CLOSESUBTREE (WM_USER+39)
#define HLB_CLOSEALLSUBTREE (WM_USER+40)
#define HLB_GETCHILDHANDLE (WM_USER+41)
#define HLBN_ERRSPACE (-2)
#define HLBN_SELCHANGE 1
#define HLBN_DBLCLK 2
#define HLBN_SELCANCEL 3
#define HLBN_SETFOCUS 4
#define HLBN_KILLFOCUS 5
#define HLBN_OPENSUBTREE 6
#define HLBN_CLOSESUBTREE 7
#define HLB_OKAY 0
#define HLB_ERR (-1)
#define HLB_ERRSPACE (-2)
#define HLB_CTLCODE 0L
typedef struct tagHIERSEARCH
{
HANDLE hSubList;
int Index;
LPSTR lpszText;
} HIERSEARCH;
typedef HIERSEARCH FAR *LPHIERSEARCH;
typedef struct tagITEMRECT
{
HANDLE hSubList;
int Index;
RECT rcItem;
WORD wLevel;
} ITEMRECT;
typedef ITEMRECT FAR *LPITEMRECT;
/* Redefinition of DRAWITEMSTRUCT & MEASUREITEMSTRUCT for the Hierarchial List Box */
typedef struct tagHLBDRAWITEMSTRUCT
{
UINT CtlType;
UINT CtlID;
HANDLE hItemHandle;
UINT ItemIndex;
UINT wLevel;
UINT itemAction;
UINT itemState;
HWND hwndItem;
HDC hDC;
RECT rcItem;
DWORD itemData;
} HLBDRAWITEMSTRUCT;
typedef HLBDRAWITEMSTRUCT FAR *LPHLBDRAWITEMSTRUCT;
typedef struct tagHLBMEASUREITEMSTRUCT
{
UINT CtlType;
UINT CtlID;
HANDLE hItemHandle;
UINT ItemIndex;
UINT wLevel;
UINT itemWidth;
UINT itemHeight;
DWORD itemData;
} HLBMEASUREITEMSTRUCT;
typedef HLBMEASUREITEMSTRUCT FAR *LPHLBMEASUREITEMSTRUCT;
/*
/*
/*************** End of Hierarchial List Box Control *****************/
/*----------------------------------------------------------------------------------*/
/* Dial Control Area */
/* */
/* The following lines pertain to the Dial Control. The Dial control is found in */
/* WICSCC.DLL. */
/*----------------------------------------------------------------------------------*/
#ifdef __cplusplus
extern "C" { /* Assume C declarations for C++ */
#endif /* __cplusplus */
int WINAPI GetDialPos (HWND hWnd);
int WINAPI SetDialPos (HWND hWnd, int nPos, BOOL fRepaint);
void WINAPI GetDialRange (HWND hWnd, int FAR *lpnMin, int FAR *lpnMax);
void WINAPI SetDialRange (HWND hWnd, int nMin, int nMax, BOOL fRedraw);
void WINAPI GetDialTurnRange (HWND hWnd, int FAR *lpnMin, int FAR *lpnMax);
void WINAPI SetDialTurnRange (HWND hWnd, int nMin, int nMax, BOOL fRedraw);
#ifdef __cplusplus
} /* End of extern "C" { */
#endif /* __cplusplus */
/*
/*
/************ End of Dial Control Section *************/
/*----------------------------------------------------------------------------------*/
/* Percent Bar Control Area */
/* */
/* The following lines pertain to the Percent Bar Control. The control is found */
/* in the WICSCC.DLL. */
/*----------------------------------------------------------------------------------*/
#define PBM_SETLIMIT WM_USER
#define PBM_SETBYTESPROCESSED WM_USER+1
/*
/*
/************ End of Percent Bar Control Section *************/
/*----------------------------------------------------------------------------------*/
/* Font Selection Control Area */
/* */
/* The following lines pertain to the Font Selection Control. The control */
/* is found in WICSCC.DLL. */
/*----------------------------------------------------------------------------------*/
#define FSN_CHANGEFONTNAME 0x00000001L
#define FSN_CHANGEFONTSIZE 0x00000002L
#define FSM_SETFONTFAMILY WM_USER+1
#define FSM_SETFONTSIZE WM_USER+2
#define FSM_GETFONTFAMILY WM_USER+3
#define FSM_GETFONTSIZE WM_USER+4
#define FSM_SETFONTCOMMANDCODE WM_USER+5
#define FSM_SETSIZECOMMANDCODE WM_USER+6
/*----------------------------------------------------------------------------------*/
/* Edit Control Area */
/* */
/* The following lines pertain to the Numeric and Date Edit Controls. The controls */
/* are found in WICSCC.DLL. */
/*----------------------------------------------------------------------------------*/
#define NES_NORMAL 0x00000000L
#define NES_LEFT 0x00000000L
#define NES_CENTER 0x00000001L
#define NES_RIGHT 0x00000002L
#define NES_ARROWCONTROLS 0x00000004L
#define NES_FORMATTED 0x00000008L
#define NES_LEDDISPLAY 0x00000010L
#define NES_COUNTERDISPLAY 0x00000020L
#define NES_BORDER 0x00000040L
#define NES_AUTOHSCROLL 0x00000080L
#define NES_NOHIDESEL 0x00000100L
#define NES_READONLY 0x00000800L
/*----------------------------------------------------------------------------------*/
/* Define special messages used by the Numeric Edit Control. */
/*----------------------------------------------------------------------------------*/
#define NEM_GETSEL WM_USER+0
#define NEM_SETSEL WM_USER+1
#define NEM_GETRECT WM_USER+2
#define NEM_GETMODIFY WM_USER+8
#define NEM_SETMODIFY WM_USER+9
#define NEM_LINELENGTH WM_USER+17
#define NEM_REPLACESEL WM_USER+18
#define NEM_SETFONT WM_USER+19
#define NEM_GETLINE WM_USER+20
#define NEM_LIMITTEXT WM_USER+21
#define NEM_GETFIRSTVISIBLELINE WM_USER+30
#define NEM_SETREADONLY WM_USER+31
#define NEM_GETEDITPARAMS WM_USER+135
#define NEM_SETEDITPARAMS WM_USER+136
#define NEM_GETLASTGOODNUMBER WM_USER+137
#define NEM_GETINTEGER WM_USER+138
#define NEM_GETLONGINT WM_USER+139
#define NEM_GETFLOAT WM_USER+140
#define NEM_GETDOUBLE WM_USER+141
#define NEM_GETLONGDOUBLE WM_USER+142
#define NEM_SETINTEGER WM_USER+143
#define NEM_SETLONGINT WM_USER+144
#define NEM_SETFLOAT WM_USER+145
#define NEM_SETDOUBLE WM_USER+146
#define NEM_SETLONGDOUBLE WM_USER+147
/*----------------------------------------------------------------------------------*/
/* Define notification messages returned by the numeric edit control. */
/*----------------------------------------------------------------------------------*/
#define NEN_SETFOCUS 0x0100
#define NEN_KILLFOCUS 0x0200
#define NEN_CHANGE 0x0300
#define NEN_UPDATE 0x0400
#define NEN_ERRSPACE 0x0500
#define NEN_MAXTEXT 0x0501
#define NEN_ERRTOOHIGH 0x0502
#define NEN_ERRTOOLOW 0x0503
#define NEN_HSCROLL 0x0601
/*----------------------------------------------------------------------------------*/
/* Define standard format codes used by the numeric edit control. */
/*----------------------------------------------------------------------------------*/
#define NEMFT_DEFAULT 0
#define NEMFT_SIMPLEINTEGER 1
#define NEMFT_COMMAINTEGER 2
#define NEMFT_PARENINTEGER 3
#define NEMFT_PARENCOMMAINT 4
#define NEMFT_SIMPLEREAL 5
#define NEMFT_COMMAREAL 6
#define NEMFT_PARENREAL 7
#define NEMFT_PARENCOMMAREAL 8
#define NEMFT_SCIENTIFIC 9
/* Numeric Edit Control parameters. Used by the NEM_SETEDITPARAMS message */
typedef struct tagNECPARMS
{
WORD wFormatType;
BOOL fLimitValue;
WORD wDecimals;
long double ldMinimumValue;
long double ldMaximumValue;
} NECPARMS;
typedef NECPARMS FAR *LPNECPARMS;
/*----------------------------------------------------------------------------------*/
/* Define the Date Edit Control Styles... */
/*----------------------------------------------------------------------------------*/
#define DES_NORMAL 0x00000000L
#define DES_CALENDARCONTROL 0x00000004L
#define DES_LEDDISPLAY 0x00000010L
#define DES_COUNTERDISPLAY 0x00000020L
#define DES_BORDER 0x00000040L
#define DES_AUTOHSCROLL 0x00000080L
#define DES_NOHIDESEL 0x00000100L
#define DES_READONLY 0x00000800L
/*----------------------------------------------------------------------------------*/
/* Define special messages used by the Date Edit Control. */
/*----------------------------------------------------------------------------------*/
#define DEM_GETEDITPARAMS WM_USER+135
#define DEM_SETEDITPARAMS WM_USER+136
#define DEM_GETDATE WM_USER+137
#define DEM_GETMONTH WM_USER+138
#define DEM_GETDAY WM_USER+139
#define DEM_GETYEAR WM_USER+140
#define DEM_SETDATE WM_USER+143
#define CALM_SETDATE WM_USER+200
#define CALM_GETDATE WM_USER+201
/*----------------------------------------------------------------------------------*/
/* Define the Time Edit Control Styles... */
/*----------------------------------------------------------------------------------*/
#define TES_NORMAL 0x00000000L
#define TES_LEDDISPLAY 0x00000010L
#define TES_COUNTERDISPLAY 0x00000020L
#define TES_BORDER 0x00000040L
#define TES_AUTOHSCROLL 0x00000080L
#define TES_NOHIDESEL 0x00000100L
#define TES_READONLY 0x00000800L
/*----------------------------------------------------------------------------------*/
/* Define special messages used by the Date Edit Control. */
/*----------------------------------------------------------------------------------*/
#define TEM_GETEDITPARAMS WM_USER+135
#define TEM_SETEDITPARAMS WM_USER+136
#define TEM_GETTIME WM_USER+137
#define TEM_GETHOUR WM_USER+138
#define TEM_GETMINUTE WM_USER+139
#define TEM_GETSECOND WM_USER+140
#define TEM_SETTIME WM_USER+143
#define CLKM_SETTIME WM_USER+200
#define CLKM_GETTIME WM_USER+201
/*----------------------------------------------------------------------------------*/
/* Define notification messages returned by the date edit control. */
/*----------------------------------------------------------------------------------*/
#define DEN_SETFOCUS 0x0100
#define DEN_KILLFOCUS 0x0200
#define DEN_CHANGE 0x0300
#define DEN_UPDATE 0x0400
#define DEN_ERRSPACE 0x0500
#define DEN_MAXTEXT 0x0501
#define DEN_HSCROLL 0x0601
#define CALN_CHANGEDATE 0x0100
#define CALN_SELECTDATE 0x0101
/*----------------------------------------------------------------------------------*/
/* Define standard format codes used by the date edit control. */
/*----------------------------------------------------------------------------------*/
#define DEMFT_DEFAULT 0
#define DEMFT_MMDDYY 0 /* MM/DD/YY */
#define DEMFT_MMDDYYY 1 /* MM/DD/YYYY */
#define DEMFT_MMYYYY 2 /* MM/YYYY */
#define DEMFT_MMMDDYYYY 3 /* MMM DD, YYYY */
#define DEMFT_MMMMDDYYYY 4 /* MMMMM DD, YYYY */
#define DEMFT_MMMDDYY 5 /* MMM/DD/YY */
#define DEMFT_YYMMDD 6 /* YYMMDD */
#define DEMFT_MMDDYYNS 7 /* MMDDYY */
/* Numeric Edit Control parameters. Used by the NEM_SETEDITPARAMS message */
typedef struct tagDECPARMS
{
WORD wFormatType;
BOOL fInitializeDate;
WORD InitialYear;
WORD InitialMonth;
WORD InitialDay;
WORD SeperatorCharacter;
} DECPARMS;
typedef DECPARMS FAR *LPDECPARMS;
typedef struct tagTECPARMS
{
BOOL fInitializeTime;
WORD InitialHour;
WORD InitialMinute;
WORD InitialSecond;
} TECPARMS;
typedef TECPARMS FAR *LPTECPARMS;
/*
/*
/************ End of Numeric Edit Control Section *************/
/*----------------------------------------------------------------------------------*/
/* */
/* Custom Color Controls Section */
/* */
/* The following section contains definitions for the Color Palette and Color */
/* Selection Plate custom controls found in WCD.DLL. These controls were created */
/* to provide a "Borland Style" ChooseColor dialog box. These controls can be made */
/* accessible from the Resource Workshop by installing the WCD.DLL. */
/* */
/* To find out how to install custom controls in the Resource Workshop, refer to */
/* the documentation that came with your complier. */
/*----------------------------------------------------------------------------------*/
/*----------------------------------------------------------------------------------*/
/* Special messages used by the Color Palette and Color Selection Plate controls. */
/*----------------------------------------------------------------------------------*/
#define WM_SETCOLOR WM_USER+200
#define WM_SETHUE WM_USER+201
#define WM_SETSATURATION WM_USER+202
#define WM_SETLUMINOSITY WM_USER+203
#define WM_SETINDEX WM_USER+204
#define WM_SETPALETTE WM_USER+205
#define WM_GETPALETTESIZE WM_USER+206
#define WM_GETPALETTE WM_USER+207
#define WM_GETCOLOR WM_USER+208
#define WM_GETSELCOLOR WM_USER+209
#define WM_GETHUE WM_USER+210
#define WM_GETSATURATION WM_USER+211
#define WM_GETLUMINOSITY WM_USER+212
#define WM_GETINDEX WM_USER+213
#define WM_ADDCOLOR WM_USER+214
#define WM_GETSOLIDCOLOR WM_USER+215
/*----------------------------------------------------------------------------------*/
/* Notification messages sent by the Color Palette Control */
/*----------------------------------------------------------------------------------*/
#define CPN_SETFOCUS 0x0100
#define CPN_KILLFOCUS 0x0200
#define CPN_CHANGE 0x0300
#define CPN_UPDATE 0x0400
/*----------------------------------------------------------------------------------*/
/* Notification messages sent by the Color Selection Plate Control */
/*----------------------------------------------------------------------------------*/
#define CSN_SETFOCUS 0x0100
#define CSN_KILLFOCUS 0x0200
#define CSN_CHANGE 0x0300
#define CSN_UPDATE 0x0400
#define CSN_SELCHANGE 0x0500
/*----------------------------------------------------------------------------------*/
/* Notification messages sent by the Color Sample Box Control */
/*----------------------------------------------------------------------------------*/
#define CSBN_SELSOLID 0x0100
#ifdef __cplusplus
extern "C" { /* Assume C declarations for C++ */
#endif /* __cplusplus */
COLORREF WINAPI RGBToHSL(COLORREF clrRGB);
COLORREF WINAPI HSLToRGB(COLORREF clrHSL);
#ifdef __cplusplus
} /* End of extern "C" { */
#endif /* __cplusplus */
/*
/*
/************ End of Custom Color Controls Section *************/
/*----------------------------------------------------------------------------------*/
/* Custom Common Dialog Box Functions */
/* */
/* The following section defines routines that provide a "Borland Style" version */
/* of the Microsoft Common Dialog Boxes that are provided with Windows 3.1. */
/* */
/* Note: The custom common dialog box functions that follow do not require a copy */
/* of COMMDLG.DLL to be installed. These are independent functions from */
/* COMMDLG.DLL, however, a copy of BWCC.DLL must be installed for these */
/* dialog boxes to work. */
/*----------------------------------------------------------------------------------*/
#ifndef __COMMDLG_H
/*--------------------------------------------------------------------------------------*/
/* */
/* Define Dialog IDs for the common dialogs. This ID is passed in wParam of the help */
/* message when the user presses the help button on a common dialog. */
/* */
/*--------------------------------------------------------------------------------------*/
#define WCDID_OPENFILENAME 1
#define WCDID_SAVEFILENAME 2
#define WCDID_CHOOSECOLOR 3
#define WCDID_CHOOSEFONT 4
#define WCDID_FINDTEXT 5
#define WCDID_REPLACETEXT 6
#define WCDID_PRINTDLG 7
#define WCDID_PRINTSETUP 8
typedef struct tagOFN
{
DWORD lStructSize;
HWND hwndOwner;
HINSTANCE hInstance;
LPCSTR lpstrFilter;
LPSTR lpstrCustomFilter;
DWORD nMaxCustFilter;
DWORD nFilterIndex;
LPSTR lpstrFile;
DWORD nMaxFile;
LPSTR lpstrFileTitle;
DWORD nMaxFileTitle;
LPCSTR lpstrInitialDir;
LPCSTR lpstrTitle;
DWORD Flags;
UINT nFileOffset;
UINT nFileExtension;
LPCSTR lpstrDefExt;
LPARAM lCustData;
UINT (CALLBACK *lpfnHook)(HWND, UINT, WPARAM, LPARAM);
LPCSTR lpTemplateName;
} OPENFILENAME;
typedef OPENFILENAME FAR* LPOPENFILENAME;
#define OFN_READONLY 0x00000001
#define OFN_OVERWRITEPROMPT 0x00000002
#define OFN_HIDEREADONLY 0x00000004
#define OFN_NOCHANGEDIR 0x00000008
#define OFN_SHOWHELP 0x00000010
#define OFN_ENABLEHOOK 0x00000020
#define OFN_ENABLETEMPLATE 0x00000040
#define OFN_ENABLETEMPLATEHANDLE 0x00000080
#define OFN_NOVALIDATE 0x00000100
#define OFN_ALLOWMULTISELECT 0x00000200
#define OFN_EXTENSIONDIFFERENT 0x00000400
#define OFN_PATHMUSTEXIST 0x00000800
#define OFN_FILEMUSTEXIST 0x00001000
#define OFN_CREATEPROMPT 0x00002000
#define OFN_SHAREAWARE 0x00004000
#define OFN_NOREADONLYRETURN 0x00008000
#define OFN_NOTESTFILECREATE 0x00010000L
#define OFN_SHAREFALLTHROUGH 2
#define OFN_SHARENOWARN 1
#define OFN_SHAREWARN 0
typedef struct tagCHOOSECOLOR
{
DWORD lStructSize;
HWND hwndOwner;
HWND hInstance;
COLORREF rgbResult;
COLORREF FAR* lpCustColors;
DWORD Flags;
LPARAM lCustData;
UINT (CALLBACK* lpfnHook)(HWND, UINT, WPARAM, LPARAM);
LPCSTR lpTemplateName;
} CHOOSECOLOR;
typedef CHOOSECOLOR FAR *LPCHOOSECOLOR;
#define CC_RGBINIT 0x00000001
#define CC_FULLOPEN 0x00000002
#define CC_PREVENTFULLOPEN 0x00000004
#define CC_SHOWHELP 0x00000008
#define CC_ENABLEHOOK 0x00000010
#define CC_ENABLETEMPLATE 0x00000020
#define CC_ENABLETEMPLATEHANDLE 0x00000040
typedef struct tagFINDREPLACE
{
DWORD lStructSize; /* size of this struct 0x20 */
HWND hwndOwner; /* handle to owner's window */
HINSTANCE hInstance; /* instance handle of.EXE that
* contains cust. dlg. template
*/
DWORD Flags; /* one or more of the FR_?? */
LPSTR lpstrFindWhat; /* ptr. to search string */
LPSTR lpstrReplaceWith; /* ptr. to replace string */
UINT wFindWhatLen; /* size of find buffer */
UINT wReplaceWithLen; /* size of replace buffer */
LPARAM lCustData; /* data passed to hook fn. */
UINT (CALLBACK* lpfnHook)(HWND, UINT, WPARAM, LPARAM);
/* ptr. to hook fn. or NULL */
LPCSTR lpTemplateName; /* custom template name */
} FINDREPLACE;
typedef FINDREPLACE FAR *LPFINDREPLACE;
#define FR_DOWN 0x00000001L
#define FR_WHOLEWORD 0x00000002L
#define FR_MATCHCASE 0x00000004L
#define FR_FINDNEXT 0x00000008L
#define FR_REPLACE 0x00000010L
#define FR_REPLACEALL 0x00000020L
#define FR_DIALOGTERM 0x00000040L
#define FR_SHOWHELP 0x00000080L
#define FR_ENABLEHOOK 0x00000100L
#define FR_ENABLETEMPLATE 0x00000200L
#define FR_NOUPDOWN 0x00000400L
#define FR_NOMATCHCASE 0x00000800L
#define FR_NOWHOLEWORD 0x00001000L
#define FR_ENABLETEMPLATEHANDLE 0x00002000L
#define FR_HIDEUPDOWN 0x00004000L
#define FR_HIDEMATCHCASE 0x00008000L
#define FR_HIDEWHOLEWORD 0x00010000L
typedef struct tagCHOOSEFONT
{
DWORD lStructSize; /* */
HWND hwndOwner; /* caller's window handle */
HDC hDC; /* printer DC/IC or NULL */
LOGFONT FAR* lpLogFont; /* ptr. to a LOGFONT struct */
int iPointSize; /* 10 * size in points of selected font */
DWORD Flags; /* enum. type flags */
COLORREF rgbColors; /* returned text color */
LPARAM lCustData; /* data passed to hook fn. */
UINT (CALLBACK* lpfnHook)(HWND, UINT, WPARAM, LPARAM);
/* ptr. to hook function */
LPCSTR lpTemplateName; /* custom template name */
HINSTANCE hInstance; /* instance handle of.EXE that
* contains cust. dlg. template
*/
LPSTR lpszStyle; /* return the style field here
* must be LF_FACESIZE or bigger */
UINT nFontType; /* same value reported to the EnumFonts
* call back with the extra FONTTYPE_
* bits added */
int nSizeMin; /* minimum pt size allowed & */
int nSizeMax; /* max pt size allowed if */
/* CF_LIMITSIZE is used */
} CHOOSEFONT;
typedef CHOOSEFONT FAR *LPCHOOSEFONT;
#define CF_SCREENFONTS 0x00000001
#define CF_PRINTERFONTS 0x00000002
#define CF_BOTH (CF_SCREENFONTS | CF_PRINTERFONTS)
#define CF_SHOWHELP 0x00000004L
#define CF_ENABLEHOOK 0x00000008L
#define CF_ENABLETEMPLATE 0x00000010L
#define CF_ENABLETEMPLATEHANDLE 0x00000020L
#define CF_INITTOLOGFONTSTRUCT 0x00000040L
#define CF_USESTYLE 0x00000080L
#define CF_EFFECTS 0x00000100L
#define CF_APPLY 0x00000200L
#define CF_ANSIONLY 0x00000400L
#define CF_NOVECTORFONTS 0x00000800L
#define CF_NOOEMFONTS CF_NOVECTORFONTS
#define CF_NOSIMULATIONS 0x00001000L
#define CF_LIMITSIZE 0x00002000L
#define CF_FIXEDPITCHONLY 0x00004000L
#define CF_WYSIWYG 0x00008000L /* must also have CF_SCREENFONTS & CF_PRINTERFONTS */
#define CF_FORCEFONTEXIST 0x00010000L
#define CF_SCALABLEONLY 0x00020000L
#define CF_TTONLY 0x00040000L
#define CF_NOFACESEL 0x00080000L
#define CF_NOSTYLESEL 0x00100000L
#define CF_NOSIZESEL 0x00200000L
/* these are extra nFontType bits that are added to what is returned to the
* EnumFonts callback routine */
#define SIMULATED_FONTTYPE 0x8000
#define PRINTER_FONTTYPE 0x4000
#define SCREEN_FONTTYPE 0x2000
#define BOLD_FONTTYPE 0x0100
#define ITALIC_FONTTYPE 0x0200
#define REGULAR_FONTTYPE 0x0400
#define WM_CHOOSEFONT_GETLOGFONT (WM_USER + 1)
/* strings used to obtain unique window message for communication
* between dialog and caller
*/
#define LBSELCHSTRING "commdlg_LBSelChangedNotify"
#define SHAREVISTRING "commdlg_ShareViolation"
#define FILEOKSTRING "commdlg_FileNameOK"
#define COLOROKSTRING "commdlg_ColorOK"
#define SETRGBSTRING "commdlg_SetRGBColor"
#define FINDMSGSTRING "commdlg_FindReplace"
#define HELPMSGSTRING "commdlg_help"
/* HIWORD values for lParam of commdlg_LBSelChangeNotify message */
#define CD_LBSELNOITEMS -1
#define CD_LBSELCHANGE 0
#define CD_LBSELSUB 1
#define CD_LBSELADD 2
typedef struct tagPD
{
DWORD lStructSize;
HWND hwndOwner;
HGLOBAL hDevMode;
HGLOBAL hDevNames;
HDC hDC;
DWORD Flags;
UINT nFromPage;
UINT nToPage;
UINT nMinPage;
UINT nMaxPage;
UINT nCopies;
HINSTANCE hInstance;
LPARAM lCustData;
UINT (CALLBACK* lpfnPrintHook)(HWND, UINT, WPARAM, LPARAM);
UINT (CALLBACK* lpfnSetupHook)(HWND, UINT, WPARAM, LPARAM);
LPCSTR lpPrintTemplateName;
LPCSTR lpSetupTemplateName;
HGLOBAL hPrintTemplate;
HGLOBAL hSetupTemplate;
} PRINTDLG;
typedef PRINTDLG FAR* LPPRINTDLG;
#define PD_ALLPAGES 0x00000000L
#define PD_SELECTION 0x00000001L
#define PD_PAGENUMS 0x00000002L
#define PD_NOSELECTION 0x00000004L
#define PD_NOPAGENUMS 0x00000008L
#define PD_COLLATE 0x00000010L
#define PD_PRINTTOFILE 0x00000020L
#define PD_PRINTSETUP 0x00000040L
#define PD_NOWARNING 0x00000080L
#define PD_RETURNDC 0x00000100L
#define PD_RETURNIC 0x00000200L
#define PD_RETURNDEFAULT 0x00000400L
#define PD_SHOWHELP 0x00000800L
#define PD_ENABLEPRINTHOOK 0x00001000L
#define PD_ENABLESETUPHOOK 0x00002000L
#define PD_ENABLEPRINTTEMPLATE 0x00004000L
#define PD_ENABLESETUPTEMPLATE 0x00008000L
#define PD_ENABLEPRINTTEMPLATEHANDLE 0x00010000L
#define PD_ENABLESETUPTEMPLATEHANDLE 0x00020000L
#define PD_USEDEVMODECOPIES 0x00040000L
#define PD_DISABLEPRINTTOFILE 0x00080000L
#define PD_HIDEPRINTTOFILE 0x00100000L
typedef struct tagDEVNAMES
{
UINT wDriverOffset;
UINT wDeviceOffset;
UINT wOutputOffset;
UINT wDefault;
} DEVNAMES;
typedef DEVNAMES FAR* LPDEVNAMES;
#define DN_DEFAULTPRN 0x0001
#endif /* End of commdlg.h exclusion */
#ifdef __cplusplus
extern "C" { /* Assume C declarations for C++ */
#endif /* __cplusplus */
BOOL WINAPI GetOpenFileName(OPENFILENAME FAR*);
BOOL WINAPI GetSaveFileName(OPENFILENAME FAR*);
int WINAPI GetFileTitle (LPCSTR, LPSTR, UINT);
BOOL WINAPI ChooseColor (CHOOSECOLOR FAR*);
BOOL WINAPI ChooseFont (CHOOSEFONT FAR*);
HWND WINAPI FindText(FINDREPLACE FAR*);
HWND WINAPI ReplaceText(FINDREPLACE FAR*);
BOOL WINAPI PrintDlg(PRINTDLG FAR*);
#ifdef __cplusplus
} /* End of extern "C" { */
#endif /* __cplusplus */
/*
/*
/************ End of Custom Common Dialog Box Section *************/
#ifdef __cplusplus
extern "C" { /* Assume C declarations for C++ */
#endif /* __cplusplus */
int FAR PASCAL GetWICSVersion (void);
int FAR PASCAL GetWCDVersion (void);
#ifdef __cplusplus
} /* End of extern "C" { */
#endif /* __cplusplus */
#ifndef RC_INVOKED
#pragma option -a. /* Revert to default packing */
#endif /* !RC_INVOKED */
#endif /* WICS_H */